home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
Champak 143
/
(Vol 143) Nov 15 2011.iso
/
Games
/
cubic_shot_3.swf
/
scripts
/
frame_3
/
DoAction.as
< prev
Wrap
Text File
|
2011-11-15
|
2KB
|
64 lines
function soundOn()
{
soundon = "yes";
_root.blockHitSound = new Sound(this);
_root.blockHitSound.attachSound("blockHitSoundM");
_root.lineThrowSound = new Sound(this);
_root.lineThrowSound.attachSound("lineThrowSoundM");
_root.lineDrawSound = new Sound(this);
_root.lineDrawSound.attachSound("lineDrawSoundM");
_root.boomSound = new Sound(this);
_root.boomSound.attachSound("boomSoundM");
_root.heartHitSound = new Sound(this);
_root.heartHitSound.attachSound("heartHitSoundM");
_root.startSound = new Sound(this);
_root.startSound.attachSound("startSoundM");
_root.buttonSound = new Sound(this);
_root.buttonSound.attachSound("buttonSoundM");
_root.readySound = new Sound(this);
_root.readySound.attachSound("readySoundM");
_root.gameOverSound = new Sound(this);
_root.gameOverSound.attachSound("gameOverSoundM");
_root.titleSound = new Sound(this);
_root.titleSound.attachSound("titleSoundM");
_root.backSound = new Sound(this);
_root.backSound.attachSound("backSoundM");
_root.backSound.setVolume(50);
if(nowF == "title")
{
_root.titleSound.start(0,999);
}
else if(nowF == "roundClear")
{
_root.roundClearSound.start(0,999);
}
else if(nowF == "main")
{
_root.backSound.start(0,999);
}
}
function soundOff()
{
soundon = "no";
delete _root.blockHitSound;
delete _root.lineThrowSound;
delete _root.boomSound;
delete _root.heartHitSound;
delete _root.startSound;
delete _root.buttonSound;
delete _root.readySound;
_root.lineDrawSound.stop();
delete _root.lineDrawSound;
_root.backSound.stop();
delete _root.backSound;
_root.titleSound.stop();
delete _root.titleSound;
_root.gameOverSound.stop();
delete _root.gameOverSound;
}
nowF == "noting";
trace("\n");
trace("-------------------------");
trace("Start : opening");
_root.soundOn();